package com.example.helloworld;

import java.util.Scanner;

public class ScannerDemoTwo {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        System.out.print("Enter a number: ");
        if (scanner.hasNextLine()) {
            String input = scanner.nextLine();
            System.out.println("You entered: " + input);
        }
        scanner.close();
    }
}
